package com.xnx3.banmahuishou.userApplet.util;

import java.util.HashMap;
import java.util.Map;
import com.xnx3.BaseVO;
import com.xnx3.DateUtil;
import com.xnx3.weixin.TemplateMessageUtil;
import com.xnx3.weixin.WeiXinAppletUtil;
import com.xnx3.weixin.applet.Global;

/**
 * 微信小程序模板消息测试
 * @author 管雷鸣
 *
 */
public class WeixinAppletTemplateMessageUtil {
	
	public static void main(String[] args) {
		//微信用户端
		
		String openid = "oYaFz5QuSjPwEvfq9zJ1AE9pc3eU";
		String templateId = "Mg3rJhtFtV4cd2PKDCwSBNOVKbXsX1Mhdh4mBrMQlIo";
		
		Map<String, String> dataMap = new HashMap<String, String>();
		dataMap.put("character_string1", DateUtil.timeForUnix10()+"");	//订单号
		dataMap.put("thing12", "管雷鸣");	//服务人员
		dataMap.put("phone_number5", "17076012262");	//联系电话
		dataMap.put("thing8", "xxx"); //回收地址
		dataMap.put("time10", "2011.1.1"); //预约时间
		BaseVO vo = Global.weixinAppletUtil.sendSubscribeTemplateMessage(templateId, openid, dataMap);
		System.out.println(vo);
	}
}
